/*
 *  group.h - Group management functions
 *  Copyright (c) 2005 Derek Ingrouville (dergro@users.sourceforge.net)
 *
 *  This program is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation; either version 2 of the License, or
 *  (at your option) any later version.
 *
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU Library General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program; if not, write to the Free Software
 *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 */

#ifndef _GROUP_H
#define _GROUP_H

#include "contact.h"

typedef struct _MsnGroup
{
    char *name;
    char *guid;
    GList *contacts;
    int num_contacts;
} MsnGroup;

MsnGroup *msn_group_new ();
MsnGroup *msn_group_from_lsg (MsnCommand *lsg);
MsnGroup *msn_group_from_adg (MsnCommand *adg);
void msn_group_free (MsnGroup *group);

int msn_group_add_contact (MsnGroup *group, MsnContact *contact);
int msn_group_remove_contact (MsnGroup *group, MsnContact *contact);
MsnContact *msn_group_find_contact_from_passport (MsnGroup *group,
                                                  const char *passport);
unsigned int msn_group_get_num_contacts_online (MsnGroup *group);

#endif /* _GROUP_H */
